﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="欠款报表设置.aspx.cs" Inherits="syc.Sale.欠款报表设置" %>


<html>
<head runat="server">
    <title></title>
</head>
<body>
<script type="text/javascript" language="javascript" src="/common.js"></script>
<form id="form1" runat="server">
  <div id="wintop" class="wintop">原料欠款设置</div>

<asp:Panel ID="Panel1" runat="server" CssClass="panel">
 <span style="display:inline-block;width:220px;text-align:right;padding-right:16px;">
        &nbsp;供货单位：<asp:DropDownList ID="GongHuo" runat="server" Width="120px" 
        AutoPostBack="true"   DataSourceID="">
          
           
        </asp:DropDownList>
    </span>
    <span style="display:inline-block;width:220px;text-align:right;padding-right:16px;">
        年 度：<asp:DropDownList ID="NianFen" runat="server" Width="120px" 
        AutoPostBack="true" onselectedindexchanged="YueFen_SelectedIndexChanged">
            <asp:ListItem>2008</asp:ListItem>
            <asp:ListItem>2009</asp:ListItem>
            <asp:ListItem>2010</asp:ListItem>
            <asp:ListItem>2011</asp:ListItem>
            <asp:ListItem>2012</asp:ListItem>
            <asp:ListItem>2013</asp:ListItem>
            <asp:ListItem>2014</asp:ListItem>
            <asp:ListItem>2015</asp:ListItem>
        </asp:DropDownList>
    </span>
    <span style="display:inline-block;width:160px;text-align:right;">
        月 份：<asp:DropDownList ID="YueFen" runat="server" Width="80px" 
        AutoPostBack="true" onselectedindexchanged="YueFen_SelectedIndexChanged">
            <asp:ListItem>1</asp:ListItem>
            <asp:ListItem>2</asp:ListItem>
            <asp:ListItem>3</asp:ListItem>
            <asp:ListItem>4</asp:ListItem>
            <asp:ListItem>5</asp:ListItem>
            <asp:ListItem>6</asp:ListItem>
            <asp:ListItem>7</asp:ListItem>
            <asp:ListItem>8</asp:ListItem>
            <asp:ListItem>9</asp:ListItem>
            <asp:ListItem>10</asp:ListItem>
            <asp:ListItem>11</asp:ListItem>
            <asp:ListItem>12</asp:ListItem>
        </asp:DropDownList> 
    </span>
    <br />
    <span style="display:inline-block;width:220px;text-align:right;">
        起始日期：<asp:TextBox ID="Date1" runat="server" CssClass="intxt1" Width="120px"></asp:TextBox><img alt="" src="/Icons/29.png" align="middle" onclick="makecalendar(document.getElementById('Date1').value, document.getElementById('Date1'));" />
    </span>
    <span style="display:inline-block;width:220px;text-align:right;">
        截止日期：<asp:TextBox ID="Date2" runat="server" CssClass="intxt1" Width="120px"></asp:TextBox><img alt="" src="/Icons/29.png" align="middle" onclick="makecalendar(document.getElementById('Date2').value, document.getElementById('Date2'));" />
    </span>
    <span style="display:inline-block;width:130px;text-align:right;">
    <asp:Button ID="Button_Save" runat="server" Text="设 置" CssClass="mbutton" 
        UseSubmitBehavior="False" onclick="Button_Save_Click"  />
    </span>

</asp:Panel>

<asp:Panel ID="Panel2" runat="server" CssClass="panel2">
    <asp:Label ID="Message" runat="server" Text="·准备就绪" CssClass="prompt"></asp:Label>
</asp:Panel>
    
<div class="gridframe">
    <div class="gridview">
    
        <table border="1" width="100%" cellspacing="0" cellpadding="0" bordercolor="#e5cfab">
            <tr>
	            <td class="grid-title">欠款时间设置</td>
	        </tr>
	        <tr>
	            <td class="grid-back">
                    <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
                        ConnectionString="<%$ ConnectionStrings:SCMConnectionString1 %>" 
                        onselected="SqlDataSource1_Selected" ></asp:SqlDataSource>
                    <asp:GridView ID="GridView1" runat="server" AllowPaging="True" 
                        AutoGenerateColumns="False" CssClass="grid" DataKeyNames="" 
                        DataSourceID="SqlDataSource1" PageSize="20"
                        GridLines="None" ondatabound="GridView1_DataBound" 
                        onpageindexchanged="GridView1_PageIndexChanged" AllowSorting="False" 
                        UseAccessibleHeader="False" >
                        <PagerSettings Visible="False" />
                        <RowStyle CssClass="tr.grid-row-fix" />
                        <Columns>                            
                            <asp:TemplateField HeaderText="ID" SortExpression="ID">
                                <ItemTemplate>
                                    <asp:Label ID="Label0" runat="server" Text='<%# Bind("ID") %>'></asp:Label>
                                </ItemTemplate>
                                <HeaderStyle CssClass="grid-header" />
                                <ItemStyle CssClass="grid" HorizontalAlign="Center" Width="80px" />
                            </asp:TemplateField>                            
                            <asp:TemplateField HeaderText="年度" SortExpression="年度">
                                <ItemTemplate>
                                    <asp:Label ID="Label1" runat="server" Text='<%# Bind("年度") %>'></asp:Label>
                                </ItemTemplate>
                                <HeaderStyle CssClass="grid-header" />
                                <ItemStyle CssClass="grid" HorizontalAlign="Center" Width="80px" />
                            </asp:TemplateField>
                            <asp:TemplateField HeaderText="月份" SortExpression="月份">
                                <ItemTemplate>
                                    <asp:Label ID="Label2" runat="server" Text='<%# Bind("月份") %>'></asp:Label>
                                </ItemTemplate>
                                <HeaderStyle CssClass="grid-header" />
                                <ItemStyle CssClass="grid" HorizontalAlign="Center" Width="80px" />
                            </asp:TemplateField>  
                            <asp:TemplateField HeaderText="起始日期" SortExpression="起始日期">
                                <ItemTemplate>
                                    <asp:Label ID="Label3" runat="server" Text='<%# Bind("起始日期","{0:D}") %>'></asp:Label>
                                </ItemTemplate>
                                <HeaderStyle CssClass="grid-header" />
                                <ItemStyle CssClass="grid" HorizontalAlign="Center" Width="120px" />
                            </asp:TemplateField>
                            <asp:TemplateField HeaderText="截止日期" SortExpression="截止日期">
                                <ItemTemplate>
                                    <asp:Label ID="Label4" runat="server" Text='<%# Bind("截止日期","{0:D}") %>'></asp:Label>
                                </ItemTemplate>
                                <HeaderStyle CssClass="grid-header" />
                                <ItemStyle CssClass="grid" HorizontalAlign="Center" Width="120px" />
                            </asp:TemplateField>

                        </Columns>
                      </asp:GridView>
	            </td>
            </tr>
            <tr>
	            <td>   
	                <table width="100%">
	                    <tr>
	                        <td class="pagebar">
                                <asp:Button ID="Button_Pager_First" runat="server" Text="" ToolTip="首页" 
                                    CssClass="pageturn-first-b" onclick="Pager_Click" CommandName="--" />
                                <asp:Button ID="Button_Pager_Prev" runat="server" Text="" ToolTip="上一页" 
                                    CssClass="pageturn-prev-b" onclick="Pager_Click" CommandName="-" />
                                <input type="button" class="page-split" />第<asp:TextBox ID="TextBox_Pager" runat="server" CssClass="pageturn" 
                                    ontextchanged="Pager_Click"></asp:TextBox>页<input type="button" class="page-split" /><asp:Label ID="Label_Pages" runat="server"></asp:Label><input type="button" class="page-split" />
                                
                                <asp:Button ID="Button_Pager_Next" runat="server" Text="" ToolTip="下一页" 
                                    CssClass="pageturn-next-b" onclick="Pager_Click" CommandName="+" />
                                <asp:Button ID="Button_Pager_Last" runat="server" Text="" ToolTip="末页" 
                                    CssClass="pageturn-last-b" onclick="Pager_Click" CommandName="++" />
                            </td>
                            <td class="pagebar" align="right">
                                <asp:Label ID="Label_Total" runat="server"></asp:Label>
                            </td>
                        </tr>
                   </table>

	            </td>
            </tr>
        </table>
        

    </div>
</div>

</form>
<script>
    var textboxs = document.getElementsByTagName("input");
    var i;
    for (i = 0; i < textboxs.length; i++) {
        if (textboxs[i].className == "textbox") {
            textboxs[i].onchange = function(e) { this.className = "textbox-changed"; };
            textboxs[i].onfocus = function(e) { this.select(); };
        }
        else if (textboxs[i].className == "pageturn" || textboxs[i].className == "intxt1" || textboxs[i].className == "intxt2") {
            textboxs[i].onfocus = function(e) { this.select(); };
        }

    }
//    document.getElementById("Date1").readOnly = true;
//    document.getElementById("Date2").readOnly = true;
</script>
</body>
</html>
